//_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/.
// 			VisualNovelToolkit		     /_/_/_/_/_/_/_/_/_/.
// Copyright ©2013 - Sol-tribe.	/_/_/_/_/_/_/_/_/_/.
//_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/.

using UnityEngine;
using System.Collections;

[ AddComponentMenu( "ViNo/Util/ThisObjectIsCached" )]
public class ThisObjectIsCached : MonoBehaviour {
	public bool useKey;
	public string key;

	void Awake(){
//		Debug.Log( "ThisObjectIsCached : " + name );
		if( useKey ){
			GOCache.Add( key , this.gameObject );
		}
		else{
			GOCache.Add( this.gameObject );		
		}
	}

}
